{% extends "cab/base.html" %}
{% load snippets %}


{% block extrahead %}
{{ block.super }}
<link rel="alternate" type="application/rss+xml" title="{{cur_site.name}} - {{feed_title}} (rss)"
 href="{% url rss_feeds "snippets" %}{{feed_url_extra}}" />
<link rel="alternate" type="application/atom+xml" title="{{cur_site.name}} - {{feed_title}} (atom)" 
 href="{% url atom_feeds "snippets" %}{{feed_url_extra}}" />
{% endblock %}


{% block title %}All Snippets - {{ block.super }}{% endblock %}

{% block content %}
<h1>All {{title_extra}} snippets</h1>

<div id="sorting-criteria">
  order by: 
  <a href="/snippets/" class="{% active request '^/snippets/$' %}">Date</a> &nbsp;  
  <a href="/snippets/rating/" class="{% active request '^/snippets/rating/$' %}">Rating</a> &nbsp; 
  <a href="/snippets/bookmarks/" class="{% active request '^/snippets/bookmarks/$' %}">Bookmarks</a> &nbsp; 
</div>


<span id="snippet_feeds" class="feeds">
Follow:
    <a class="feedlink" href="{% url rss_feeds "snippets" %}{{feed_url_extra}}" rel="alternate"  type="application/rss+xml">
       <img class="feedicon" src="{{MEDIA_URL}}images/rss_icon.png" alt="rss icon"/>
    </a>
    <a class="feedlink" href="{% url atom_feeds "snippets" %}{{feed_url_extra}}" rel="alternate"  type="application/atom+xml">
       <img class="feedicon" src="{{MEDIA_URL}}images/atom_icon.png" alt="atom icon"/>
    </a>
    {% if subscribe_by_mail %}
    {% subscription_link request "s" %}
    {% endif %}
</span>



{% if object_list %}
<ul>
{% for snippet in object_list %}
<li>{% if show_count %} 
       <span title="{{count_title}}">{{snippet.count}}</span>
    {% endif %}
        {% show_snippet snippet %}
    </li>
{% endfor %}
</ul>

{% paginator %}
<p>{{ hits }} snippet{{ hits|pluralize }} {% if action %}{{action}}{% else %}posted{% endif %} so far.</p>
{% else %}
<p>No snippets {% if action %}{{action}}{% else %}posted{% endif %} yet.</p>
{% endif %}



{% endblock %}